package com.example.tutorialhtmlit;


import android.annotation.SuppressLint;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
public class TutorialhtmlitActivity extends Activity implements OnClickListener {
 /** Called when the activity is first created. */
@Override
	public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	setContentView(R.layout.main);
	final Button button = (Button) findViewById(R.id.form_button);
	button.setOnClickListener(this);
	}
	@SuppressLint({ "ParserError", "ParserError" })
	@Override
	public void onClick(View v) {
	// TODO Auto-generated method stub
	switch ( v.getId() ) {
	case R.id.form_button:
	final EditText edit_name = (EditText)findViewById(R.id.edit_name);
	final EditText edit_lastname = (EditText)findViewById(R.id.edit_lastname);
	Bundle bundle = new Bundle();
	bundle.putString("name", edit_name.getText().toString());
	bundle.putString("lastname", edit_lastname.getText().toString());
	Intent form_intent = new Intent(getApplicationContext(), Form.class);
	form_intent.putExtras(bundle);
	startActivity(form_intent);
 break;
}
}
}